package org.dromara.sms4j;

import org.dromara.sms4j.core.datainterface.SmsReadConfig;
import org.dromara.sms4j.huawei.config.HuaweiConfig;
import org.dromara.sms4j.provider.config.BaseConfig;
import org.dromara.sms4j.unisms.config.UniConfig;
import org.springframework.stereotype.Component;
import sms4j.local.LocalConfig;

import java.util.ArrayList;
import java.util.List;

@Component
public class MyConfig implements SmsReadConfig {
    @Override
    public BaseConfig getSupplierConfig(String configId) {
        HuaweiConfig huaweiConfig = new HuaweiConfig();
        huaweiConfig.setConfigId("hw");
        //你的参数
        return huaweiConfig;
    }

    @Override
    public List<BaseConfig> getSupplierConfigList() {
        List<BaseConfig> configs =  new ArrayList<BaseConfig>();
        UniConfig uniConfig = new UniConfig();
        uniConfig.setConfigId("uni");
        //你的参数
        uniConfig.setMaximum(6);
        configs.add(uniConfig);

        LocalConfig localConfig = new LocalConfig();
        localConfig.setConfigId("local");
        //你的参数
        localConfig.setMaximum(6);
        configs.add(localConfig);
        return configs;
    }
}